Precision machine vision inspection systems (or “vision systems” for short) can be utilized to obtain precise dimensional measurements of inspected objects and to inspect various other object characteristics. Such systems may include a computer, a camera and optical system, and a precision stage that is movable in multiple directions to allow workpiece inspection. One exemplary prior art system, that can be characterized as a general-purpose “off-line” precision vision system, is the commercially available QUICK VISION® series of PC-based vision systems and QVPAK® software available from Mitutoyo America Corporation (MAC), located in Aurora, Ill. The features and operation of the QUICK VISION® series of vision systems and the QVPAK® software are generally described, for example, in the QVPAK 3D CNC Vision Measuring Machine User's Guide, published January 2003, and the QVPAK 3D CNC Vision Measuring Machine Operation Guide, published September 1996, each of which is hereby incorporated by reference in their entirety. This type of system is able to use a microscope-type optical system and move the stage so as to provide inspection images of either small or relatively large workpieces at various magnifications.
General purpose precision machine vision inspection systems, such as the QUICK VISION™ system, are also generally programmable to provide automated video inspection. U.S. Pat. No. 6,542,180 (the '180 patent) teaches various aspects of such automated video inspection and is incorporated herein by reference in its entirety. As taught in the '180 patent, automated video inspection metrology instruments generally have a programming capability that allows an automatic inspection event sequence to be defined by the user for each particular workpiece configuration. This can be implemented by text-based programming, for example, or through a recording mode which progressively “learns” the inspection event sequence by storing a sequence of machine control instructions corresponding to a sequence of inspection operations performed by a user with the aid of a graphical user interface, or through a combination of both methods. Such a recording mode is often referred to as “learn mode” or “training mode” or “record mode.” Once the inspection event sequence is defined in “learn mode,” such a sequence can then be used to automatically acquire (and additionally analyze or inspect) images of a workpiece during “run mode.”
The machine control instructions including the specific inspection event sequence (i.e., how to acquire each image and how to analyze/inspect each acquired image) are generally stored as a “part program” or “workpiece program” that is specific to the particular workpiece configuration. For example, a part program defines how to acquire each image, such as how to position the camera relative to the workpiece, at what lighting level, at what magnification level, etc. Further, the part program defines how to analyze/inspect an acquired image, for example, by using one or more video tools such as edge/boundary detection video tools.
Video tools (or “tools” for short) include GUI features and predefined image analysis operations such that operation and programming can be performed by non-expert operators. Video tools may be operated by a user to accomplish manual inspection and/or machine control operations (in “manual mode”). Their set-up parameters and operation can also be recorded during learn mode, in order to create automatic inspection programs. Exemplary video tools include edge location measurement tools, which are used to locate an edge feature of a workpiece, and which may include a tool configuration referred to as a “box tool” used to isolate an edge in a region of interest and then automatically determine the edge location. For example, commonly assigned U.S. Pat. No. 7,627,162, which is incorporated herein by reference in its entirety, teaches various applications of box tools.
Known edge location measurement tools use image intensity to determine edge locations. Intensity gradients are analyzed along scan lines (comprising pixel brightness or intensity values) that cross the edge. The maximum gradient location is frequently used as the edge location. However, it remains difficult to reliably locate “noisy” edges, such as the edges of irregular or highly textured surfaces or irregular edges produced by sawing or laser cutting, when using an intensity gradient method. The resulting scan lines are frequently too noisy to support reliable edge location measurements.
Another known type of video tool is sometimes referred to as a “multipoint tool” or a “multipoint autofocus tool” video tool. Such a tool provides Z-height measurements or coordinates (along the optical axis and focusing axis of the camera system) derived from a “best focus” position for a plurality of sub-regions at defined X-Y coordinates within a region of interest of the tool, such as determined by an contrast based “autofocus” method, sometimes referred to as a points from focus (PFF) reconstruction. A set of such X,Y,Z coordinates may be referred as point cloud data, or a point cloud, for short. In general, according to prior art autofocus methods and/or tools, the camera moves through a range of positions along a z-axis (the focusing axis) and captures an image at each position (referred to as an image stack). For each captured image, a focus metric is calculated for each sub-region based on the image and related to the corresponding position of the camera along the Z-axis at the time that the image was captured. This results in focus curve data for each sub-region, which may be referred to simply as a “focus curve” or “autofocus curve.” The peak of the focus curve, which corresponds to the best focus position along the z-axis, may be found by fitting a curve to the focus curve data and estimating the peak of the fitted curve. Variations of such autofocus methods are well known in the art. For example, one known method of autofocusing similar to that outlined above is discussed in “Robust Autofocusing in Microscopy”, by Jan-Mark Geusebroek and Arnold Smeulders in ISIS Technical Report Series, Vol. 17, November 2000. Another known autofocus method and apparatus is described in U.S. Pat. No. 5,790,710, which is hereby incorporated by reference in its entirety.
Some methods are known for post processing point cloud data and identifying edge features in the point cloud. However, such methods do not resemble the known intensity based edge location measurement tools outlined above (e.g. a box tool, or the like), in that the methods are considerably more complex to understand and apply and are generally not suitable for relatively unskilled users. In addition, certain issues may arise when determining a plurality of 3D data points across the surface of a workpiece and/or an edge, and attempting to use the resulting 3D data points together to determine the location or Z profile of the edge. Accuracies in the micron or sub-micron range are often desired in precision machine vision inspection systems. This is particularly challenging with regard to Z-height measurements around an edge. A particular problem arises in points from focus (PFF) reconstruction around an edge, in that the local contrast around each image pixel (corresponding to a point cloud X-Y location) is typically based on or averaged within a square neighborhood centered on that location (e.g. 7×7 pixels) to reduce noise in the contrast curve and to enable reliable Z depth reconstruction. However, in general, this distorts or “smoothes” the edge profile in the point cloud data, and reduces the accuracy and resolution of the profile across the edge. As a result, it remains difficult to determine an accurate profile and/or location for certain types of edges, for example “noisy” edges, such as the edges of irregular surfaces or irregular edges produced by sawing or laser cutting. Video tools and/or automatic operations that allow non-expert users to determine profiles for such edges with improved reliability and/or repeatability would be desirable.